Oh my tmux
https://github.com/gpakosz/.tmux
cd
git clone --single-branch <https://github.com/gpakosz/.tmux.git>
ln -s -f .tmux/.tmux.conf
cp .tmux/.tmux.conf.local .
Bindings
tmux may be controlled from an attached client by using a key combination of a
prefix key, followed by a command key. This configuration uses C-a as a
secondary prefix while keeping C-b as the default prefix. In the following
list of key bindings:
<prefix>means you have to either hitCtrl+aorCtrl+b<prefix> cmeans you have to hitCtrl+aorCtrl+bfollowed byc<prefix> C-cmeans you have to hitCtrl+aorCtrl+bfollowed byCtrl+c
This configuration uses the following bindings:
<prefix> eopens the.localcustomization file copy with the editor defined by theEDITORenvironment variable (defaults tovimwhen empty)<prefix> rreloads the configurationC-lclears both the screen and the tmux history<prefix> C-ccreates a new session<prefix> C-flets you switch to another session by name<prefix> C-hand<prefix> C-llet you navigate windows (default<prefix> nis unbound and<prefix> pis repurposed)<prefix> Tabbrings you to the last active window<prefix> -splits the current pane vertically<prefix> _splits the current pane horizontally<prefix> h,<prefix> j,<prefix> kand<prefix> llet you navigate panes ala Vim<prefix> H,<prefix> J,<prefix> K,<prefix> Llet you resize panes<prefix> <and<prefix> >let you swap panes<prefix> +maximizes the current pane to a new window<prefix> mtoggles mouse mode on or off<prefix> Ulaunches Urlscan (preferred) or Urlview, if available<prefix> Flaunches Facebook PathPicker, if available<prefix> Enterenters copy-mode<prefix> blists the paste-buffers<prefix> ppastes from the top paste-buffer<prefix> Plets you choose the paste-buffer to paste from
Additionally, copy-mode-vi matches my own Vim configuration
Bindings for copy-mode-vi:
vbegins selection / visual modeC-vtoggles between blockwise visual mode and visual modeHjumps to the start of lineLjumps to the end of lineycopies the selection to the top paste-bufferEscapecancels the current operation
It's also possible to preserve the tmux stock bindings by setting the
tmux_conf_preserve_stock_bindings variable to true in your .local
customization file copy.